import { _decorator, Component, Node } from 'cc';
import { Item } from './Item';
const { ccclass, property } = _decorator;

// 道具类，继承自物品类
@ccclass('DaoJu')
export class DaoJu extends Item {
    
    itemType: string='道具';
    @property
    toolEffect: string = ''; // 添加道具效果属性

    constructor(name: string, description: string, quantity: number, itemType: string, toolEffect: string='未知效果') {
        super(name, description, itemType, quantity); // 传递物品类型参数
        this.toolEffect = toolEffect; // 初始化道具效果属性
    }
}

